/*
 * @author wilbur.ma@qq.com
 * @date 2011.06.01
 * Requrie jquery and jquery.url
 * Requrie fold_lib for simple template
 */
 function show_cur_host() {
	fold_all_except($("#hosts > div"), $($.url().attr("fragment")));
 }
 
 window.onload = function(event) {
	$("#showall").click(function(event) { show_all($("#hosts > div")); });
	$("#hideall").click(function(event) { fold_all($("#hosts > div")); });
	$(".index_name").each(function() {
		$(this).click(function(event) { 
			fold_all_except($("#hosts > div"), $(this).parent());
		})
	});
    show_cur_host();
};